package DesignPrinciple.Demeter;

public class Client {
    public static void main(String[] args) {
        /*
            明星与粉丝、明星与公司无须直接通信
            不应当发生直接的相互调用，可以通过第三方（Agent经纪人）转发该调用
         */
        Company company = new Company("有限");
        Fans fans = new Fans("龙口");
        Star star = new Star("冥王");

        Agent agent = new Agent();
        agent.setCompany(company);
        agent.setFans(fans);
        agent.setStar(star);

        agent.meeting();
        agent.bussiness();
    }
}
